<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style type="text/css">
        table {border-collapse: collapse; font-size: 14px; width: 80%; margin: auto}
        table, th, td {border: 1px solid darkslategray;padding: 10px}
    </style>
</head>
<body>

<a th:href="@{/product/productShang}">上架</a>
<table class="list">
    <tr>
        <th>id</th>
        <th>商品名称</th>
        <th>商品价格</th>
        <th>商品日期</th>
        <th>商品状态</th>
        <th>操作</th>
    </tr>
    <tr th:each="do : ${dome}">
        <td th:text="${do.id}"></td>
        <td th:text="${do.name}"></td>
        <td th:text="${do.jg}+'￥'"></td>
        <td th:text="${#dates.format(do.birthday,'yyyy-MM-dd')}"></td>
        <td th:text="${do.status}"></td>
        <td>
            <a th:href="@{/product/productad(id=${do.id})}" th:if="${do.status==2}">通过</a>
            <a th:href="@{/product/productud(id=${do.id})}" th:if="${do.status==2}">失败</a>
        </td>
    </tr>
</table>
</body>
</html>
